import request from '@/util/request'
import type { Order, OrderItem, OrderParam } from './types'

const api = '/order-service/order'
const orderItemApi = '/order-service/orderItem'

    /** 创建订单 */
export const createOrder = (order: OrderParam) => {
    return request<any,any>({
        url: api,
        method: 'post',
        data: order
    })
}

/** 获取订单详情 */
export const getOrderItemDetail = (orderNo: string) => {
    return request<any,any>({
        url: orderItemApi + '/detail',
        method: 'get',
        params: { orderNo }
    })
}


















